package cn.tedu.egarticle0618.base.config;

import io.swagger.v3.oas.models.OpenAPI;
import io.swagger.v3.oas.models.tags.Tag;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

import java.util.Arrays;
import java.util.List;

@Configuration
public class Knife4jConfig {
    @Bean
    public OpenAPI customOpenAPI() {
        return new OpenAPI().tags(getTagOrdered());
    }

    private List<Tag> getTagOrdered() {
        return Arrays.asList(
                new Tag().name("用户模块").description("用于用户管理的接口")
        );
    }
}
